#include <stdio.h>
#include <stdlib.h>
#include <time.h>

int main(int argc, char const * argv[])
{
    int RNG;
    srand(time(NULL));
    RNG = rand() %100 +1;
    int guess=0;
    while (guess != RNG)
    {
    printf("请输入你猜的数：");
    scanf("%d", &guess);
    if ( guess < RNG )
    {
        printf("你猜小了\n");
    }
    else if (guess > RNG )
    {
        printf("你猜大了\n");
    }
    }
    printf("你猜对了\n");
    
    return 0;
}